package com.tjetc.字符转换流;

import java.io.*;

public class T02InputStreamReader {
    public static void main(String[] args) throws IOException {
       //最里面的那层
        FileInputStream fileInputStream = new FileInputStream("b.txt");
        //转换流
        InputStreamReader inputStreamReader = new InputStreamReader(fileInputStream,"UTF-8");
         //缓冲流
        BufferedReader bufferedReader = new BufferedReader(inputStreamReader);
        //每次读取的一行,相对与水杯
        String line ;
        while((line = bufferedReader.readLine())!=null){
            System.out.println(line);
        }
        //关闭流
        bufferedReader.close();


    }
}
